<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('新增分销积分设定')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-bonus-add">
            <div class="form-group">
                <label class="col-sm-3 control-label">账户性质：</label>
                <div class="col-sm-8">
                    <div class="radio-box" th:each="dict : ${@dict.getType('account_type')}">
                        <input type="radio" th:id="${'accountType_' + dict.dictCode}" name="accountType" th:value="${dict.dictValue}" th:checked="${dict.default}">
                        <label th:for="${'accountType_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                    </div>
                </div>
            </div>


            <div class="form-group">
                <label class="col-sm-3 control-label is-required">一级分销奖励积分：</label>
                <div class="col-sm-8">
                    <input name="gbonus" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">二级分销奖励积分：</label>
                <div class="col-sm-8">
                    <input name="fbonus" class="form-control" type="text" required>
                </div>
            </div>
<!--            <div class="form-group">    -->
<!--                <label class="col-sm-3 control-label">上级分销用户名：</label>-->
<!--                <div class="col-sm-8">-->
<!--                    <input name="puserName" class="form-control" type="text">-->
<!--                </div>-->
<!--            </div>-->
<!--            <div class="form-group">    -->
<!--                <label class="col-sm-3 control-label">用户ID：</label>-->
<!--                <div class="col-sm-8">-->
<!--                    <input name="userId" class="form-control" type="text">-->
<!--                </div>-->
<!--            </div>-->
<!--            <div class="form-group">    -->
<!--                <label class="col-sm-3 control-label">用户名：</label>-->
<!--                <div class="col-sm-8">-->
<!--                    <input name="userName" class="form-control" type="text">-->
<!--                </div>-->
<!--            </div>-->
            <div class="form-group">
                <label class="col-sm-3 control-label">备注：</label>
                <div class="col-sm-8">
                    <textarea name="remark" class="form-control"></textarea>
                </div>
            </div>

        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/bonus"
        $("#form-bonus-add").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/add", $('#form-bonus-add').serialize());
            }
        }
    </script>
</body>
</html>